﻿<Window xmlns:UIElements="clr-namespace:SymulatorEthernetWPF.UserInterface.UIElements"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:Shared="clr-namespace:SymulatorEthernetWPF.Shared"  x:Class="SymulatorEthernetWPF.UserInterface.HubSettings"
        Title="Ustawienia urządzenia" Height="231.3" Width="434.266"
        ResizeMode="CanMinimize" WindowStartupLocation="CenterOwner" Icon="Images/AppIco.ico">
    <Window.Resources>
        <Shared:BooleanNotConverter x:Key="BooleanNotConverter"/>
        <Style x:Key="NoChromeButton" TargetType="{x:Type Button}">
            <Setter Property="Background" Value="Transparent" />
            <Setter Property="BorderThickness" Value="1" />
            <Setter Property="Foreground" Value="{DynamicResource {x:Static SystemColors.ControlTextBrushKey}}" />
            <Setter Property="HorizontalContentAlignment" Value="Center" />
            <Setter Property="VerticalContentAlignment" Value="Center" />
            <Setter Property="Padding" Value="1" />
            <Setter Property="Template">
                <Setter.Value>
                    <ControlTemplate TargetType="{x:Type Button}">
                        <Grid x:Name="Chrome" Background="{TemplateBinding Background}" SnapsToDevicePixels="true">
                            <ContentPresenter HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
                                Margin="{TemplateBinding Padding}" RecognizesAccessKey="True"
                                SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}"
                                VerticalAlignment="{TemplateBinding VerticalContentAlignment}" />
                        </Grid>
                        <ControlTemplate.Triggers>
                            <Trigger Property="IsEnabled" Value="false">
                                <Setter Property="Foreground" Value="#ADADAD" />
                                <Setter Property="Opacity" TargetName="Chrome" Value="0.5" />
                            </Trigger>
                        </ControlTemplate.Triggers>
                    </ControlTemplate>
                </Setter.Value>
            </Setter>
        </Style>
    </Window.Resources>
    <Grid>
        <Button Content="Anuluj" Height="23" Margin="0,0,10,10" x:Name="cancelButton" VerticalAlignment="Bottom"
        HorizontalAlignment="Right" Width="75" Click="CancelButtonClick" IsCancel="True" Grid.Column="1" />
        <Button Content="OK" HorizontalAlignment="Right" Margin="0,0,90,10" x:Name="okButton" Width="75" Click="OkButtonClick" IsDefault="True" Grid.Column="1" Height="23" VerticalAlignment="Bottom" />
        <Grid Margin="0,10,0,0" Height="154" VerticalAlignment="Top">
            <CheckBox Content="" Height="16" HorizontalAlignment="Left" Margin="108,30,0,0" x:Name="isInterface1Enabled"
              VerticalAlignment="Top" Width="20" />
            <TextBox Height="23" Margin="13,26,0,0" x:Name="interface1Name" VerticalAlignment="Top"
             HorizontalAlignment="Left" Width="89" />
            <CheckBox Content="" Height="16" HorizontalAlignment="Left" Margin="108,58,0,0" x:Name="isInterface2Enabled"
              VerticalAlignment="Top" Width="20" />
            <TextBox Height="23" Margin="13,54,0,0" x:Name="interface2Name" VerticalAlignment="Top"
             HorizontalAlignment="Left" Width="89" />
            <CheckBox Content="" Height="16" HorizontalAlignment="Left" Margin="108,87,0,0" x:Name="isInterface3Enabled"
              VerticalAlignment="Top" Width="20" />
            <TextBox Height="23" Margin="13,82,0,0" x:Name="interface3Name" VerticalAlignment="Top"
             HorizontalAlignment="Left" Width="89" />
            <CheckBox Content="" Height="16" HorizontalAlignment="Left" Margin="108,114,0,0" x:Name="isInterface4Enabled"
              VerticalAlignment="Top" Width="20" />
            <TextBox Height="23" Margin="13,110,0,0" x:Name="interface4Name" VerticalAlignment="Top"
             HorizontalAlignment="Left" Width="89" />
            <CheckBox Content="" Height="16" HorizontalAlignment="Right" Margin="0,30,104,0" x:Name="isInterface5Enabled"
              VerticalAlignment="Top" Width="20" />
            <TextBox Height="23" Margin="0,26,10,0" x:Name="interface5Name" VerticalAlignment="Top"
             HorizontalAlignment="Right" Width="89" />
            <CheckBox Content="" Height="16" HorizontalAlignment="Right" Margin="0,58,104,0" x:Name="isInterface6Enabled"
              VerticalAlignment="Top" Width="20" />
            <TextBox Height="23" Margin="0,54,10,0" x:Name="interface6Name" VerticalAlignment="Top"
             HorizontalAlignment="Right" Width="89" />
            <CheckBox Content="" Height="16" HorizontalAlignment="Right" Margin="0,87,104,0" x:Name="isInterface7Enabled"
              VerticalAlignment="Top" Width="20" />
            <TextBox Height="23" Margin="0,82,10,0" x:Name="interface7Name" VerticalAlignment="Top"
             HorizontalAlignment="Right" Width="89" />
            <CheckBox Content="" Height="16" HorizontalAlignment="Right" Margin="0,114,104,0" x:Name="isInterface8Enabled"
              VerticalAlignment="Top" Width="20" />
            <TextBox Height="23" Margin="0,110,10,0" x:Name="interface8Name" VerticalAlignment="Top"
             HorizontalAlignment="Right" Width="89" />

            <Button Style="{DynamicResource NoChromeButton}"  VerticalAlignment="Top"
        		Margin="0,47,0,0" x:Name="iconButton" Click="IconButtonClick" Height="52" HorizontalAlignment="Center">
                <Grid HorizontalAlignment="Center">
                    <Image Height="48" Width="64" x:Name="deviceIcon" Stretch="Fill" VerticalAlignment="Top" ToolTip="Kliknij aby zmienić symbol dla tego urządzenia" ForceCursor="False" Cursor="Hand" Margin="12,0" />
                    <Rectangle Fill="Black" Height="8" HorizontalAlignment="Left" Margin="0,0,0,0" x:Name="networkInterface1Handler"
        				Stroke="Black" VerticalAlignment="Top" Width="8" />
                    <Rectangle Fill="Black" Height="8" HorizontalAlignment="Left" Margin="0,14,0,0" x:Name="networkInterface2Handler"
        				Stroke="Black" VerticalAlignment="Top" Width="8" />
                    <Rectangle Fill="Black" Height="8" HorizontalAlignment="Left" Margin="0,28,0,0" x:Name="networkInterface3Handler"
        				Stroke="Black" VerticalAlignment="Top" Width="8" />
                    <Rectangle Fill="Black" Height="8" HorizontalAlignment="Left" Margin="0,42,0,0" x:Name="networkInterface4Handler"
        				Stroke="Black" VerticalAlignment="Top" Width="8" />
                    <Rectangle Fill="Black" Height="8" HorizontalAlignment="Left" Margin="80,0,0,0"
        				x:Name="networkInterface5Handler" Stroke="Black" VerticalAlignment="Top" Width="8" />
                    <Rectangle Fill="Black" Height="8" HorizontalAlignment="Left" Margin="80,14,0,0"
        				x:Name="networkInterface6Handler" Stroke="Black" VerticalAlignment="Top" Width="8" />
                    <Rectangle Fill="Black" Height="8" HorizontalAlignment="Left" Margin="80,28,0,0"
        				x:Name="networkInterface7Handler" Stroke="Black" VerticalAlignment="Top" Width="8" />
                    <Rectangle Fill="Black" Height="8" HorizontalAlignment="Left" Margin="80,42,0,0"
        				x:Name="networkInterface8Handler" Stroke="Black" VerticalAlignment="Top" Width="8" />
                </Grid>

            </Button>
            <TextBox  Margin="0,104,0,0" x:Name="deviceName" VerticalAlignment="Top" MaxLines="1"
            	MaxLength="10" FontWeight="Bold" Text="TEST" HorizontalAlignment="Center" Width="96" TextAlignment="Center"/>
            <TextBlock Text="Koncentrator" Margin="0,27,0,0" VerticalAlignment="Top" x:Name="deviceType" FontStyle="Italic"  Width="96" HorizontalAlignment="Center" TextAlignment="Center">
                <TextBlock.Foreground>
                    <SolidColorBrush Color="{DynamicResource {x:Static SystemColors.WindowFrameColorKey}}"/>
                </TextBlock.Foreground>
            </TextBlock>
            <Label Content="Nazwa" HorizontalAlignment="Left" Margin="8,0,0,0" VerticalAlignment="Top"/>
            <Label Content="Nazwa" HorizontalAlignment="Right" Margin="0,0,60,0" VerticalAlignment="Top"/>
            <Label Content="Aktywny" HorizontalAlignment="Left" Margin="104,0,0,0" VerticalAlignment="Top"/>
            <Label Content="Aktywny" HorizontalAlignment="Right" Margin="0,0,102,0" VerticalAlignment="Top"/>
        </Grid>



    </Grid>
</Window>